@layout("/common/_container.html",{plugins:["ztree"],js:["/assets/modular/system/user/user.js"]}){
<div class="layui-body-header">
    <span style="line-height: 36px;">用户管理</span>
    <div style="float:right;">
        @if(shiro.hasPermission("/mgr/add")){
        <button id="btnAdd" style="font-size: 14px;" class="layui-btn layui-btn-lg layui-btn-radius layui-btn-primary">
            <img style="width: 16px;height: 16px;margin-bottom: 4px;" src="${ctxPath}/assets/common/images/add.svg"/>&nbsp;添 加
        </button>
        @}
    </div>
</div>

<div class="layui-fluid">
    <div class="layui-row layui-col-space15">
        <div class="layui-col-sm12 layui-col-md3 layui-col-lg2">
            <div class="layui-card">
                <div class="layui-card-body mini-bar">
                    <div class="ztree" id="deptTree"></div>
                </div>
            </div>
        </div>
        <div class="layui-col-sm12 layui-col-md9 layui-col-lg10">
            <div class="layui-card">
                <div class="layui-card-body">
                    <div class="layui-form toolbar">
                        <div class="layui-form-item">
                            <div class="layui-inline">
                                <input id="name" class="layui-input" type="text" placeholder="账号/姓名/手机号"/>
                            </div>
                            <div class="layui-inline">
                                <input id="timeLimit" class="layui-input" type="text" readonly="readonly" placeholder="注册时间"/>
                            </div>
                            <div class="layui-inline">
                                <button id="btnSearch" class="layui-btn icon-btn " style="height: 36px;line-height: 36px"><i class="layui-icon">&#xe615;</i>搜索</button>
                                <button id="reset"  class="layui-btn layui-btn-primary" style="height: 36px;line-height: 36px">
                                    重置
                                </button>
                            </div>
                            </div>
                        </div>
                    </div>
                    <table class="layui-table" id="userTable" lay-filter="userTable"></table>
                </div>
            </div>
        </div>
    </div>
</div>

<script type="text/html" id="tableBar">
    @if(shiro.hasPermission("/mgr/edit")){
    <a class=" v" lay-event="edit" >修改 </a><div class="vi"></div>
    @}
    @if(shiro.hasPermission("/mgr/delete")){
    <a class=" v" lay-event="delete" >删除 </a><div class="vi"></div>
    @}
    @if(shiro.hasPermission("/mgr/setRole")){
    <a class=" v" lay-event="roleAssign" >分配角色 </a>
        @if(shiro.hasPermission("/mgr/reset")){
        <div class="vi"></div>
        @}
    @}
    @if(shiro.hasPermission("/mgr/reset")){
    <a class=" v" lay-event="reset" >重置密码 </a>
    @}
</script>

<script type="text/html" id="statusTpl">
    <input type="checkbox" lay-filter="status" value="{{d.userId}}" lay-skin="switch" lay-text="正常|冻结" {{d.status=='ENABLE'?'checked':''}} />
</script>
@}